The present invention relates to an interface for communication between a first device and a second device comprising signalling lines and at least eight data lines.
The invention also relates to a method for communication over such an interface.
A number of interfaces for communication between two devices are known.
One example of such an interface is the Universal Serial Bus (USB), which is a serial cable bus that supports data exchange between a host computer and a wide range of simultaneously accessible peripherals. The peripherals attached to the USE share USB bandwidth through a host-scheduled token-based protocol. For example the USB is used to connect a PC, acting as host, to a keyboard, a mouse, a monitor, a speaker, a printer etc., via connection boxes, referred to as hubs, in a variety of constellations.
Another example is Fire Wire, IEEE P1394 High Performance Serial Bus, which is a serial bus supporting both backplane busses and cable. This system supports up to 16 connections simultaneously.
Yet another example is the SCSI standard which is a parallel asynchronous peer-to-peer I/O bus connecting up to 16 SCSI devices. The purpose of the SCSI bus is to connect multiple devices to one or more computers and getting a high throughput of data, even if the devices are connected by a 6 m or a 25 m cable. For the purpose of connecting multiple devices the devices are daisy-chained together by a cable with at least 50-lines. To manage the communication with different units the system is using addresses corresponding to identities of the different units.
Another example is a parallel port according to IEEE 1284, which generally is used to connect an external peripheral device to a computer via a cable. A parallel port has been used for communication between computers and peripheral devices for a long time, and therefore many computers and peripheral devices in use today are using it to communicate with each other. New and better protocols and schemes for communication is developed all the time and the parallel port is no exception. The fact that there are old devices utilising the parallel port results in a problem regarding whether to let all parallel ports be compatible with each other or to make the port better. This problem is solved by making a new parallel port be compatible with all prior ports and by making two connected ports negotiate regarding what scheme to use in the communication. As mentioned above the parallel port is designed to communicate via a cable. To give the user greater freedom in choosing where to place the two connected devices in relation to each other the parallel port is designed to be able to communicate via a 17 m cable. This results in advantages, for example, a scanner and a computer do not have to share the small amount of free space on a crowded desk and a noisy printer do not have to be placed in the same room as persons using it to print.
The use of the SCSI standard system or the parallel port for connections over short distances would however make the solution expensive and complex. Further, such a solution would have rather large energy consumption and it would require much space. In respect of a solution with the parallel port it would result in some interface functions being too slow.
Yet another example is the PCI Local Bus, which is a synchronous addressable bus interface. The bus is intended for use as an interconnect mechanism between highly integrated peripheral controller components, peripheral add-in boards, and processor memory systems. The purpose of the bus is to solve the bottleneck problem between a processor and a display peripheral in a graphics-oriented operating system. This is achieved by moving peripheral functions with high bandwidth requirements closer to the processor of a system.
A solution for connection between only two devices using the PCI Local Bus would be unsuitably complex, and thereby too expensive, and would require much space.
The object of the present invention is to provide a new interface for a connection between a first device, e.g. a peripheral device, and a second device, e.g. a network interface card, which interface is especially suitable for connections over short distances. This is attained by an asynchronous interface for communication between a first and a second device, comprising signalling lines and at least eight data lines. The asynchronous interface is characterised by:
a signal ground line, a power supply line and a power supply ground line between the two devices, and
only seven signalling lines between the two devices,
the seven signalling lines being
NICClk, which provides an output from the first device for handshaking when data is transferred in a forward direction,
PrntClk, which provides an output from the second device for handshaking when data is transferred in the forward direction and a reverse direction respectively,
NICAck, which provides an output from the first device for handshaking when data is transferred in the reverse direction,
NICBUsReq, which provides an output from the first device for indicating that it is ready for a change in transfer direction and as a request to the second device to complete the change of transfer direction immediately,
PrntBusAck, which provides an output from the second device for acknowledging a change of transfer direction, i.e. from forward to reverse or reverse to forward,
NICInt, which provides an output from the second device for requesting data transfer in the reverse direction and for requesting, when the transfer in the reverse direction is finished, the interface to return to a normal mode,
Prntint, which provides an output from the first device for requesting the interface to be reinitialised.
The lesser number of signalling lines according to the inventive solution, relatively to the prior art parallel interfaces, results in a more simple construction of the interface. By making the signalling lines carry signals according to the invention a relatively fast interface is provided. By the provision of precisely seven signalling lines carrying signals according to the inventive solution, an optimised balance between the signalling rate and the simplicity of the interface is achieved. In addition, these features provide a small and cheap interface and as a result thereof less number of components are needed for the implementation.
In a further advantageous embodiment the devices comprise signal drivers to handle the communication via the interface, which are capable of sinking at most 8 mA and of sourcing at most 8 mA. This embodiment provides the advantage of making it possible to use more cost-effective components.
The object of the present invention is also attained by a method for communication by an asynchronous interface, which comprises the steps of;
the first and the second device being in a normal mode where data transmission from the first to the second device is possible, i.e. data is transmitted or the interface is waiting for data to be transmitted, and the second device intends to transmit data to the first device,
the second device altering an output NICInt from a first state to a second state, to inform the first device that it has data to transmit and to request a.change in transfer direction from a forward direction to a reverse direction,
the first device subsequently altering an output, NICBusReq, from a first state to a second state when it has no more data to transmit, to inform the second device that it is idle and ready to receive data and to request the second device to complete the change of transfer direction,
the second device responding to this by altering an output PrntBusAck from a first state to a second state as an acknowledgement to the output NICBusReq of the first device and to acknowledge that the change of transfer direction is completed,
the second device subsequently making data, which it intends to send, available to the first device on data lines and sequentially to that altering an output PrntClk from a first state to a second state, to inform the first device that data is available,
the first device altering an output NICAck from a first state to a second state, to acknowledge that it has noticed that data is available,
the second device subsequently altering the output PrntClk from the second state to the first state, to acknowledge that it has noticed the change of state of the output NICAck,
the first device subsequently altering the output NICAck from the first state to the second state, to acknowledge that data is received and that it is ready to receive new data,
possible further data transmissions being conducted in the same manner as mentioned above until the second device has no further data to transmit, after which it alters the output NICInt from the first state to the second state, to inform the first device that it has concluded its transmission,
the first device altering the output NICtusReq from the second state to the first state in response to the output NICInt of the second device, to indicate that it is prepared to operate as a transmitter and to request the second device to complete the change of transmitting direction,
the second device acknowledging this by altering the output PrntBusAck from the second state to the first state, to inform the first device that it is prepared to operate as a receiver and to finally return the interface to the normal mode.
This method enables a fast change in transmission directions, i.e. from transmission in a forward direction to transmission in a reverse direction and vice versa.
In another aspect of the invention the method further comprises comprising the steps of
the first device setting its outputs in the second state-at initialisation and reinitialisation,
the first device altering its outputs from the second state to the first state, which is the state of these outputs in normal mode, when it has finished initialisation,
the second device setting its outputs in the second state at initialisation and reinitialisation,
the first device altering its outputs from the second state to the first state, which is the state of these outputs in normal mode, when it has finished initialisation,
the interface not allowing data transmission until both the outputs of the first device and the outputs of the second device are in the first state, i.e. the interface is in normal mode.
This aspect of the invention has an advantage of being a simple method for initialisation of the interface and completes the initialisation within a short time interval. The short time interval of the initialisation procedure is a result of a minimum of communication over the interface.
Within the context of the invention a peripheral device is a device for data storage, external communication or other tasks in a computer system. A peripheral device is for example a printer, a modem, a scanner, a fax machine, a photocopier or a multifunction peripheral.